package com.alameda.mapper.manage;

import com.alameda.manage.pojo.TechnicalIndicatorDO;
import com.alameda.manage.vo.TechnicalIndicatorVO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.Collection;
import java.util.List;

/**
 * 技术指标 数据控制层
 *
 * @author Lv
 * @date 2024/08/04
 */
@Mapper
public interface TechnicalIndicatorMapper extends BaseMapper<TechnicalIndicatorDO> {
    /**
     * 查询技术指标
     *
     * @param page                         分页对象
     * @param projectId                    项目id
     * @param likeTechnicalIndicatorRemark 技术指标描述
     * @param state                        状态
     * @param priority                     优先级
     * @param indexNo                      指标编号
     * @return
     */
    IPage<TechnicalIndicatorVO> findTechnicalIndicatorInfo(@Param("page") IPage<TechnicalIndicatorDO> page,
                                                           @Param("projectId") Long projectId,
                                                           @Param("likeTechnicalIndicatorRemark") String likeTechnicalIndicatorRemark,
                                                           @Param("state") Integer state,
                                                           @Param("priority") String priority,
                                                           @Param("indexNo") String indexNo);

    /**
     * 通过项目id集合查询
     *
     * @param idCollection 项目id集合
     * @return
     */
    List<TechnicalIndicatorVO> findByIdIn(@Param("idCollection") Collection<Long> idCollection);
}
